/**
 *
 * 游戏开始界面
 *
 */
class GameStartPanel extends BasePanel{

    public constructor(){
        super();
    }

    private bg: egret.Bitmap;
    private startBtn:EButton;
    private helpBtn:EButton;
    private setBtn: EButton;
	
	
    // 初始化面板
    public initPanel():void{
        this.bg = new egret.Bitmap();
        this.bg.texture = this.assets.getTexture("alertBg");
        this.bg.x = 60;
        this.bg.y = 274;
        var rect:egret.Rectangle = new egret.Rectangle(180,125,1,1);
        this.bg.scale9Grid =rect;
        this.bg.width = 359;
        this.bg.height = 340;
        this.addChild(this.bg);
        this.bg.touchEnabled = true;

        this.startBtn = new EButton(this,"continueBtn",this.continueBtnHandle,"",30,3);
        this.startBtn.x = this.w/2 - this.startBtn.width/2;
        this.startBtn.y = this.h/2 - this.startBtn.height/2;        
        this.addChild(this.startBtn);

        this.helpBtn = new EButton(this,"helpBtn",this.helpBtnHandle,"",30,3);
        this.helpBtn.x = 137;
        this.helpBtn.y = 520;
        this.addChild(this.helpBtn);
		
        this.setBtn = new EButton(this,"setBtn",this.setBtnHandle,"",30,3);
        this.setBtn.x = 300;
        this.setBtn.y = 520;
        this.addChild(this.setBtn);

    }
    private continueBtnHandle(): void {
        GameManager.i.GameStart();
		Global.dispatchEvent(MainNotify.closeStartPanelNotify);
    }
    private helpBtnHandle(): void {

    }
    private setBtnHandle(): void {

    }
    public onBtnTouch(e: egret.TouchEvent): void {
        
    }


}


